clear
use "C:\Papers\New papers\John Cronyism\Italy\Bilanci3.dta", clear
drop Debito tangibility lnsize revisedUtile lnmktcap DebitidivInfl lnUtile growth Lev Lev2 lnequity stlnequity stROE stlnsize stMB MB MBMediobanca Div Preminetti Sinpagati Accant Adamm Ammrischi

/*the following commands are run because numeric variables are sometimes formatted as US numbers (with commas for thousands) and sometimes as European numbers (with periods for thousands)*/
tostring CapSoc, gen(newCapSoc)
gen period_presentCapSoc =  strpos(newCapSoc, ".") > 0 
gen CapSocOld=CapSoc
replace CapSoc = CapSoc *1000 if period_presentCapSoc==1
drop newCapSoc period_presentCapSoc 
tostring Attivo, gen(newAttivo)
gen period_presentAttivo =  strpos(newAttivo, ".") > 0
gen AttivoOld=Attivo
replace Attivo= Attivo *1000 if period_presentAttivo==1
drop newAttivo period_presentAttivo
tostring UtilePerdita, gen(newUtilePerdita)
gen period_presentUtilePerdita =  strpos(newUtilePerdita, ".") > 0
gen UtilePerditaOld= UtilePerdita
replace UtilePerdita= UtilePerdita*1000 if period_presentUtilePerdita ==1
drop period_presentUtilePerdita newUtilePerdita

tostring BeniMat, gen(newBeniMat)
gen period_presentBeniMat =  strpos(newBeniMat, ".") > 0
gen BeniMat2= BeniMat
replace BeniMat2= BeniMat *1000 if period_presentBeniMat==1
drop BeniMat
rename BeniMat2 BeniMat
tostring Scorte, gen(newScorte)
gen period_presentScorte =  strpos(newScorte, ".") > 0
gen Scorte2= Scorte
replace Scorte2= Scorte *1000 if period_presentScorte==1
drop Scorte
rename Scorte2 Scorte
tostring Titoli, gen(newTitoli)
gen period_presentTitoli =  strpos(newTitoli, ".") > 0
gen Titoli2= Titoli
replace Titoli2= Titoli *1000 if period_presentTitoli==1
drop Titoli
rename Titoli2 Titoli
tostring Cassaecrediti, gen(newCassaecrediti)
gen period_presentCassaecrediti =  strpos(newCassaecrediti, ".") > 0
gen Cassaecrediti2= Cassaecrediti
replace Cassaecrediti2= Cassaecrediti *1000 if period_presentCassaecrediti==1
drop Cassaecrediti
rename Cassaecrediti2 Cassaecrediti
tostring Cassaeportafoglio, gen(newCassaeportafoglio)
gen period_presentCassaeportafoglio =  strpos(newCassaeportafoglio, ".") > 0
gen Cassaeportafoglio2= Cassaeportafoglio
replace Cassaeportafoglio2= Cassaeportafoglio *1000 if period_presentCassaeportafoglio==1
drop Cassaeportafoglio
rename Cassaeportafoglio2 Cassaeportafoglio
tostring Anticipazioniriportimutui, gen(newAnticipazioniriportimutui)
gen period_presentAnticip =  strpos(newAnticipazioniriportimutui, ".") > 0
gen Anticipazioniriportimutui2= Anticipazioniriportimutui
replace Anticipazioniriportimutui2= Anticipazioniriportimutui *1000 if period_presentAnticip==1
drop Anticipazioniriportimutui
rename Anticipazioniriportimutui2 Anticipazioniriportimutui
tostring CCatt, gen(newCCatt)
gen period_presentCCatt =  strpos(newCCatt, ".") > 0
gen CCatt2= CCatt
replace CCatt2= CCatt *1000 if period_presentCCatt==1
drop CCatt
rename CCatt2 CCatt
tostring Creditidiv, gen(newCreditidiv)
gen period_presentCreditidiv =  strpos(newCreditidiv, ".") > 0
gen Creditidiv2= Creditidiv
replace Creditidiv2= Creditidiv *1000 if period_presentCreditidiv==1
drop Creditidiv
rename Creditidiv2 Creditidiv
tostring Partitevarieatt, gen(newPartitevarieatt)
gen period_presentPartitevarieatt =  strpos(newPartitevarieatt, ".") > 0
gen Partitevarieatt2= Partitevarieatt
replace Partitevarieatt2= Partitevarieatt *1000 if period_presentPartitevarieatt==1
drop Partitevarieatt
rename Partitevarieatt2 Partitevarieatt

egen Attivo2 = rowtotal( BeniMat Scorte Titoli Cassaecrediti Cassaeportafoglio Anticipazioniriportimutui CCatt Creditidiv Partitevarieatt )

replace Attivo=Attivo2 if Attivo2>Attivo & Attivo2!=.
replace Attivo=Attivo2 if Attivo==.



merge 1:1 id Anno using "C:\Papers\New papers\John Cronyism\Italy\Taccuino Wide Janet 09-13-2024 Checked.dta"
drop if _merge==2
drop _merge
destring AttivoTaccuino , force replace
replace Attivo= AttivoTaccuino if AttivoTaccuino!=.

/*This generates Table 2*/
gen CapSoc2=CapSoc
replace CapSoc2=0 if CapSoc==.
sort Anno, stable
by Anno: egen Order=rank(-CapSoc2) if CapSoc2!=.& ConnectedDummyFY!=., unique
gen large1=0
replace large1=1 if Order >0&Order<=150& Order!=.
by Anno: summarize ConnectedDummyFY if large1==1&T!=.

gen large2=0
replace large2=1 if Order >150&Order<=500& Order!=.
by Anno: summarize ConnectedDummyFY if large2==1&T!=.

gen large3=0
replace large3=1 if Order >500&Order<=10000& Order!=.
by Anno: summarize ConnectedDummyFY if large3==1&T!=.

summarize ConnectedDummyFY if large1==1&T!=.
summarize ConnectedDummyFY if large2==1&T!=.
summarize ConnectedDummyFY if large3==1&T!=.

drop if Attivo<CapSoc+UtilePerdita 
gen Debt=Attivo- CapSoc-UtilePerdita 
gen Leverage=Debt/Attivo
sort id Anno
tsset id Anno
gen DuPontsROA= UtilePerdita/Attivo
drop ROE
gen ROE= UtilePerdita/CapSoc
gen lnsize=ln(Attivo* Numeriindicidelcostodellavi)
gen lnequity=ln(CapSoc* Numeriindicidelcostodellavi)
gen revisedUtile= UtilePerdita* Numeriindicidelcostodellavi
gen lnmktcap=ln(MktCapMillions* Numeriindicidelcostodellavi)
tsset id Anno
gen lnequitynominal=ln(CapSoc)
gen lnsizenominal=ln(Attivo)

gen MBMediobanca= MktCapMillions*1000/ CapSoc

gen MB=MBMediobanca
replace MB=MBSole if MB==.& PriceType==1
gen lnMB=ln(MB)

drop if Anno<1911|Anno>1960
drop if Fascista==.
drop if CapSoc==.|Attivo==.|UtilePerdita==.

winsor2 Leverage DuPontsROA ROE UtilePerdita CapSoc Attivo lnequity lnequitynominal lnsize lnsizenominal  MB lnMB, cuts(1 99) replace by(Anno)

/*This generates the summary statistics and the summary stats Table 2, Panel B*/
summarize Fascista Leverage DuPontsROA ROE  UtilePerdita CapSoc Attivo lnequity lnequitynominal lnsize lnsizenominal  MB lnMB

tabstat Fascista Leverage DuPontsROA ROE  UtilePerdita CapSoc Attivo lnequity lnequitynominal lnsize lnsizenominal  MB lnMB, statistics(mean median sd min max) columns(statistics)

egen stROE=std(ROE)	
egen stlnsize=std(lnsize)
egen stlnequity=std(lnequity)
egen stlnsizenominal=std(lnsizenominal)
egen stlnequitynominal=std(lnequitynominal)
egen stDuPontsROA=std(DuPontsROA)
egen stLeverage=std(Leverage)
gen Sede2=Sede
replace Sede="ALBIATE" if Sede=="PONTE ALBIATE"
replace Sede="ALZANO LOMBARDO" if Sede=="ALZANO MAGGIORE"
replace Sede="AOSTA" if Sede=="AOSTA"
replace Sede="BASSANO DEL GRAPPA" if Sede=="BASSANO"
replace Sede="BIELLA" if Sede=="BIELLA FAVARO"
replace Sede="BIELLA" if Sede=="COSSILA"
replace Sede="BOLZANO" if Sede=="BOLZANO/BOZEN"
replace Sede="BOVISIO-MASCIAGO" if Sede=="BOVISIO MOMBELLO"
replace Sede="BRIVIO" if Sede=="BRIVIO BEVERATE"
replace Sede="BUSTO ARSIZIO" if Sede=="SACCONAGO"
replace Sede="CAERANO DI SAN MARCO" if Sede=="CAERANO SAN MARCO"
replace Sede="CAFASSE" if Sede=="CAFASSE TORINESE"
replace Sede="CALALZO DI CADORE" if Sede=="CALALZO"
replace Sede="CANTU'" if Sede=="CANTÙ"
replace Sede="CASTELL'ALFERO" if Sede=="CASTELL'ALFERO D'ASTI"
replace Sede="CASTELNUOVO NIGRA" if Sede=="SALE CASTELNUOVO"
replace Sede="CERIALE" if Sede=="CERIALE LIGURE"
replace Sede="CIRIE'" if Sede=="CIRIÈ"
replace Sede="CITTA' DI CASTELLO" if Sede=="CITTÀ DI CASTELLO"
replace Sede="CIVITANOVA MARCHE" if Sede=="PORTOCIVITANOVA"
replace Sede="COMO" if Sede=="ALBATE"
replace Sede="COMO" if Sede=="PONTE CHIASSO"
replace Sede="COMO" if Sede=="REBBIO"
replace Sede="CONEGLIANO" if Sede=="CONEGLIANO VENETO"
replace Sede="COSTA MASNAGA" if Sede=="COSTAMASNAGA"
replace Sede="CREMA" if Sede=="OMBRIANO"
replace Sede="CUORGNE'" if Sede=="CUORGNÈ"
replace Sede="CUTIGLIANO" if Sede=="CUTIGLIANO PISTOIESE"
replace Sede="ERBA" if Sede=="CASSINA MARIAGA"
replace Sede="ERBA" if Sede=="ERBA INCINO"
replace Sede="FORNOVO DI TARO" if Sede=="FORNAVO TARO"
replace Sede="FORNOVO DI TARO" if Sede=="FORNOVO TARO"
replace Sede="GARDONE RIVIERA" if Sede=="FASANO DI GARDONE"
replace Sede="GAVI" if Sede=="GAVI LIGURE"
replace Sede="GAZZANIGA" if Sede=="GAZZANICA"
replace Sede="GENOVA" if Sede=="BORZOLI"
replace Sede="GENOVA" if Sede=="CORNIGLIANO LIGURE"
replace Sede="GENOVA" if Sede=="NERVI"
replace Sede="GENOVA" if Sede=="PEGLI"
replace Sede="GENOVA" if Sede=="PONTEDECIMO"
replace Sede="GENOVA" if Sede=="QUARTO DEI MILLE"
replace Sede="GENOVA" if Sede=="RIVAROLO LIGURE"
replace Sede="GENOVA" if Sede=="S. GIOVANNI BATTISTA"
replace Sede="GENOVA" if Sede=="SAMPIERDARENA"
replace Sede="GENOVA" if Sede=="SESTRI PONENTE"
replace Sede="GODIASCO" if Sede=="SALICE TERME"
replace Sede="IMPERIA" if Sede=="ONEGLIA"
replace Sede="IMPERIA" if Sede=="PORTO MAURIZIO"
replace Sede="LAVENO-MOMBELLO" if Sede=="LAVENO"
replace Sede="LAVENO-MOMBELLO" if Sede=="LAVENO MOMBELLO"
replace Sede="LECCO" if Sede=="CASTELLO SOPRA LECCO"
replace Sede="LOCATE DI TRIULZI" if Sede=="LOCATE TRIULZI"
replace Sede="LUINO" if Sede=="CREVA (LUINO)"
replace Sede="LUISAGO" if Sede=="PORTICHETTO LUISSAGO"
replace Sede="MARNATE" if Sede=="MARNATE (BUSTO ARSIZIO)"
replace Sede="MATHI" if Sede=="MATHI CANAVESE"
replace Sede="MESSINA" if Sede=="GAZZI"
replace Sede="MILANO" if Sede=="LAMBRATE"
replace Sede="MILANO" if Sede=="MUSOCCO"
replace Sede="MILANO" if Sede=="REGOREDO"
replace Sede="MILANO" if Sede=="ROGOREDO"
replace Sede="MONDOVI'" if Sede=="MONDOVÌ"
replace Sede="MONDOVI'" if Sede=="MONDOVÌ BREO"
replace Sede="MORBEGNO" if Sede=="MORBENGO"
replace Sede="NAPOLI" if Sede=="BAGNOLI DI NAPOLI"
replace Sede="NAPOLI" if Sede=="S. GIOVANNI A TEDUCCIO"
replace Sede="NAPOLI" if Sede=="S.GIOVANNI A TEDUCCIO"
replace Sede="NETRO" if Sede=="NETRO-BIELLA"
replace Sede="NOLA" if Sede=="NOLA CANAVESE"
replace Sede="NOLE" if Sede=="NOLE CANAVESE"
replace Sede="PALAZZOLO SULL'OGLIO" if Sede=="PALAZZOLO DULL'OGLIO"
replace Sede="PESCARA" if Sede=="CASTELLAMMARE ADRIATICO"
replace Sede="PIANELLO DEL LARIO" if Sede=="PIANELLO LARIO"
replace Sede="PIOVE DI SACCO" if Sede=="PIOVENGA"
replace Sede="PONTECAGNANO FAIANO" if Sede=="PONTECAGNANO"
replace Sede="PORTO VALTRAVAGLIA" if Sede=="PORTOVALTRAVAGLIA"
replace Sede="RANCIO VALCUVIA" if Sede=="RANCIO"
replace Sede="RESINA" if Sede=="RESINA (PUGLIANO)"
replace Sede="REZZATO" if Sede=="VIRLE TREPONTI"
replace Sede="RIVOLI" if Sede=="CASCINE VICA RIVOLI"
replace Sede="RIVOLI" if Sede=="RIVOLI VICA"
replace Sede="ROE' VOLCIANO" if Sede=="ROÈ"
replace Sede="ROSIGNANO MARITTIMO" if Sede=="ROSIGNANO"
replace Sede="SALSOMAGGIORE TERME" if Sede=="SALSOMAGGIORE"
replace Sede="SAN CATALDO" if Sede=="S. CATALDO"
replace Sede="SAN DONA' DI PIAVE" if Sede=="DONÀ DI PIAVE"
replace Sede="SAN DONA' DI PIAVE" if Sede=="SAN DONÀ DI PIAVE"
replace Sede="SAN GEMINI" if Sede=="SANGEMINI"
replace Sede="SAN REMO" if Sede=="SANREMO"
replace Sede="SERAVEZZA" if Sede=="QUERCETA"
replace Sede="SERAVEZZA" if Sede=="SCRAVEZZA"
replace Sede="SERAVEZZA" if Sede=="SERA"
replace Sede="TAURIANOVA" if Sede=="RADICENA"
replace Sede="TERLANO" if Sede=="VILIPIANO"
replace Sede="TERLANO" if Sede=="VILPIANO"
replace Sede="TOSCOLANO MADERNO" if Sede=="TOSCOLANO"
replace Sede="TRINO" if Sede=="TRINO VERCELLESE"
replace Sede="VALLE MOSSO" if Sede=="CAMPORE DI VALLEMOSSO"
replace Sede="VALLE MOSSO" if Sede=="CROCEMOSSO"
replace Sede="VALLE MOSSO" if Sede=="VALLEMOSSO"
replace Sede="VENEZIA" if Sede=="MARGHERA"
replace Sede="VENEZIA" if Sede=="MESTRE"
replace Sede="VENEZIA" if Sede=="MURANO"
replace Sede="VENEZIA" if Sede=="VENEZIA GIUDECCA"
replace Sede="VENEZIA" if Sede=="VENEZIA MARGHERA"
replace Sede="VERBANIA" if Sede=="INTRA"
replace Sede="VERBANIA" if Sede=="PALLANZA"
replace Sede="VERBANIA" if Sede=="VERBANIA INTRA"
replace Sede="VERBANIA" if Sede=="VERBANIA PALLANZA"
replace Sede="VERRES" if Sede=="VERRES"
replace Sede="VICOPISANO" if Sede=="ULIVETO"
replace Sede="VILLA SAN GIOVANNI" if Sede=="VILLA S. GIOVANNI"
replace Sede="VILLANUOVA SUL CLISI" if Sede=="BOSTONE"
sort id Anno
tsset id Anno
gen ROE2= UtilePerdita/ L.CapSoc
winsor2 ROE2, cuts(1 99) replace by(Anno)
sort id Anno
tsset id Anno
gen ROE3= UtilePerdita/ ((L.CapSoc+ CapSoc)/2)
winsor2 ROE3, cuts(1 99) replace by(Anno)
sort id T
tsset id T

/*The commands below generate the results in Table 6*/
reghdfe ConnectedDummyFY L.ConnectedDummyFY FascistaF L.stROE L.stlnequity D.stlnequity L.stLeverage  shock2, absorb(  i.Anno i.Ss_n i.Prov_n ) cluster(id)
est sto m1
reghdfe ConnectedDummyFY L.ConnectedDummyFY L.OandD_Who_Became_Politician  FascistaF L.stROE L.stlnequity D.stlnequity L.stLeverage  shock2, absorb(  i.Anno i.Ss_n i.Prov_n ) cluster(id)
est sto m2
reghdfe ConnectedDummyFY L.stROE L.stlnequity D.stlnequity  L.stLeverage  shock2, absorb(id  i.Anno i.Ss_n i.Prov_n ) cluster(id)
est sto m3
reghdfe ConnectedDummyFY FascistaF stROE stlnequity stLeverage if Anno>1944, absorb(  i.Anno i.Ss_n i.Prov_n ) cluster(id)
est sto m4
esttab m1 m2 m3 m4, se star( * 0.1 ** 0.05 *** 0.01) scalar(F) r2 
esttab m1 m2 m3 m4 using "C:\Papers\New papers\John Cronyism\Italy\Table6.csv", replace starl( * 0.10 ** 0.05 *** 0.010) stats(N r2 ar2)  se(3) b(3) nogap
eststo clear


sort id T
tsset id T
gen ChangeInd=0 if T==5 &Ss_n!=.&F3.Ss_n!=.
replace ChangeInd=1 if Ss_n!=F3.Ss_n&Ss_n!=.&F3.Ss_n!=.
summarize ChangeInd
gen ChangeLoc=0 if T==5 &Prov_n!=.&F3.Prov_n!=.
replace ChangeLoc=1 if Prov_n!=F3.Prov_n&Prov_n!=.&F3.Prov_n!=.
sort id
by id: egen Change1=max(ChangeLoc)
by id: egen Change2=max(ChangeInd)
gen Change=max(Change1,Change2)


tsset id Anno
by id: egen Count2143=count(id) if Anno>=1921&Anno<=1943
by id: egen Count19211943=max(Count2143)
by id: egen Count4460=count(id) if Anno>=1944&Anno<=1960
by id: egen Count19441960=max(Count4460)
sort Anno
save "C:\Papers\New papers\John Cronyism\Italy\Bilanci10.dta", replace
sort id T
tsset id T

sort id
by id: egen FascistaKept=max(FascistaKeptPF)
replace FascistaKept=0 if FascistaKept==.
gen Fascista19441950Kept= Fascista19441950* FascistaKept
sort id
by id: egen OandD_Bec_FascPol=max(OandD_Who_Became_FascPol)
gen OandD_Fpol_kept19441950= OandD_Bec_FascPol * Fascista19441950Kept
replace OandD_Fpol_kept19441950=0 if OandD_Fpol_kept19441950==.

/*The commands below generate the results in Table 7*/
reghdfe  ROE  stlnequity stLeverage Fascista1940 Fascista1941 Fascista1942 Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951 Fascista1952 Fascista1953 Fascista1954 Fascista1955 Fascista1956 Fascista1957 Fascista1958 Fascista1959 Fascista1960 total_tons total_tons1940 total_tons1941 total_tons1942 total_tons1943 total_tons1944 total_tons1945 total_tons1946 total_tons1947 total_tons1948 total_tons1949 total_tons1950 total_tons1951 total_tons1952 total_tons1953 total_tons1954 total_tons1955 total_tons1956 total_tons1957 total_tons1958 total_tons1959 total_tons1960, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m1

reghdfe  ROE  stlnequity stLeverage Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m2

reghdfe  ROE  stlnequity stLeverage Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus if Anno>=1921, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m3

reghdfe  ROE  stlnequity stLeverage Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus if Anno>=1939, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m4

reghdfe  ROE  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus , absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m5

reghdfe  ROE  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno##i.Ss_n i.Anno##i.Prov_n) cluster(id)
est sto m6

esttab m1 m2 m3 m4 m5 m6, se star( * 0.1 ** 0.05 *** 0.01) scalar(F) r2 
esttab m1 m2 m3 m4 m5 m6 using "C:\Papers\New papers\John Cronyism\Italy\Table7.csv", replace starl( * 0.10 ** 0.05 *** 0.010) stats(N r2 ar2)  se(3) b(3) nogap
eststo clear

/*The commands below generate the results in Table 7 using DuPont's ROA*/
reghdfe  DuPontsROA  stlnequity stLeverage Fascista1940 Fascista1941 Fascista1942 Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951 Fascista1952 Fascista1953 Fascista1954 Fascista1955 Fascista1956 Fascista1957 Fascista1958 Fascista1959 Fascista1960 total_tons total_tons1940 total_tons1941 total_tons1942 total_tons1943 total_tons1944 total_tons1945 total_tons1946 total_tons1947 total_tons1948 total_tons1949 total_tons1950 total_tons1951 total_tons1952 total_tons1953 total_tons1954 total_tons1955 total_tons1956 total_tons1957 total_tons1958 total_tons1959 total_tons1960, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m1

reghdfe  DuPontsROA  stlnequity stLeverage Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m2

reghdfe  DuPontsROA  stlnequity stLeverage Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus if Anno>=1921, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m3

reghdfe  DuPontsROA  stlnequity stLeverage Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus if Anno>=1939, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m4

reghdfe  DuPontsROA  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus , absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m5

reghdfe  DuPontsROA  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno##i.Ss_n i.Anno##i.Prov_n) cluster(id)
est sto m6

esttab m1 m2 m3 m4 m5 m6, se star( * 0.1 ** 0.05 *** 0.01) scalar(F) r2 
esttab m1 m2 m3 m4 m5 m6 using "C:\Papers\New papers\John Cronyism\Italy\Table7B.csv", replace starl( * 0.10 ** 0.05 *** 0.010) stats(N r2 ar2)  se(3) b(3) nogap
eststo clear

merge n:1 id Anno using "C:\Papers\New papers\John Cronyism\Italy\Listed Mediobanca.dta"
drop if _merge==2
drop _merge
summarize PubliclyTraded
replace PubliclyTraded=1 if MB!=.
replace PubliclyTraded=1 if MktCapMillions!=.
replace PubliclyTraded=0 if PubliclyTraded==.
gen PubliclyTraded19441950=PubliclyTraded
gen FascistaPublic=PubliclyTraded*Fascista
replace PubliclyTraded19441950=0 if Anno<1944|Anno>1950
gen Fascista19441950Public=Fascista* PubliclyTraded19441950
reghdfe  ROE  stlnequity stLeverage  Fascista19441950 Fascista1951Plus  total_tons total_tons19431950 total_tons1951Plus Fascista19441950Public PubliclyTraded FascistaPublic PubliclyTraded19441950, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m1 
summarize AnnoFondazione, detail
gen Old=1 if AnnoFondazione<=1918& AnnoFondazione!=.
replace Old=0 if AnnoFondazione>1918& AnnoFondazione!=.
gen Old19441950=Old
replace Old19441950=0 if Anno<1944|Anno>1950
gen Fascista19441950Old=Fascista* Old19441950
gen FascistaOld=Old*Fascista
reghdfe  ROE  stlnequity stLeverage  Fascista19441950 Fascista1951Plus  total_tons total_tons19431950 total_tons1951Plus Fascista19441950Old Old FascistaOld Old19441950 , absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m2
summarize stlnequity, detail
gen Large=1 if stlnequity >= -.0700179& stlnequity!=.
replace Large=0 if stlnequity < -.0700179& stlnequity!=.
gen Large19441950=Large
replace Large19441950=0 if Anno<1944|Anno>1950
gen Fascista19441950Large=Fascista* Large19441950
gen FascistaLarge=Large*Fascista
reghdfe  ROE  stlnequity stLeverage Fascista19441950 Fascista1951Plus  total_tons total_tons19431950 total_tons1951Plus Fascista19441950Large Large Large19441950 FascistaLarge, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m3
gen FascistMediaCo=1 if id==16225|id==12239|id==21813|id==90454|id==90460
sort id
by id: egen FascistMediaCompany=max(FascistMediaCo)
/* According to ChatFPT, Fiat (id==8575), Montecatini (id== 19857),  Ansaldo (id== 1341), IRI (Istituto per la Ricostruzione Industriale) (id== 15832), some unspecified companies under IRI's control, Italgas (id== 16204) Banco di Roma (id== 2607), ENI (then Azienda Generale Italiana Petroli) (id= 631), INA (Istituto Nazionale delle Assicurazioni) (id= 16070), and Publishing and Media Companies (Ss="DE") active during the regime were boycotted or faced backlash following the fall of the regime*/ 
/* According to keyword sarches in Il Corriere for keyword "boicottaggio" during 1/1/1943-1/1/1951, Alfa Romeo (id=994), Edison (id=19861), Fiat (id=8575), Ilva (id=16475), Snia Fibre (id=25152), certain editorial companies were boycotted following the fall of fascism. Those searches also criticize Isotta Fraschini (id=8920), and IRI (id=15832) for their unjustifiably low productivity (viewed as a form of boycotting).*/
/* According to both sources, the command is the following*/
gen Boycotts=1 if id==8575| id== 19857| id== 1341| id== 15832|id==2607|id== 631 |id== 16204|id== 16070 | id==994 |id==19861|id==16475|id==25152 |id==8920 |FascistMediaCompany==1
replace Boycotts=0 if Boycotts==.
reghdfe  ROE  stlnequity stLeverage  Fascista19441950 Fascista1951Plus  total_tons total_tons19431950 total_tons1951Plus if Boycotts!=1, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)

est sto m4

gen FascistPre1921=Fascista
replace FascistPre1921=0 if Anno>=1921
reghdfe  ROE  stlnequity stLeverage Fascista19441950 Fascista1951Plus FascistPre1921 total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m5

esttab m1 m2 m3 m4 m5 , se star( * 0.1 ** 0.05 *** 0.01) scalar(F) r2 
esttab m1 m2 m3 m4 m5 using "C:\Papers\New papers\John Cronyism\Italy\Table9.csv", replace starl( * 0.10 ** 0.05 *** 0.010) stats(N r2 ar2)  se(3) b(3) nogap
eststo clear

/*Results discussed in footnote 12*/
gen ROE1960=ROE if Anno==1960
sort id
by id: egen FROE1960=mean(ROE1960)
gen ROE1939=ROE if Anno==1939
sort id
by id: egen FROE1939=mean(ROE1939)
reghdfe  ROE  stlnequity  Fascista19441950 Fascista1951Plus  total_tons total_tons19431950 total_tons1951Plus  if FROE1939!=.& FROE1960!=., absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m105
gen ROE1950=ROE if Anno==1950
sort id
by id: egen FROE1950=mean(ROE1950)
reghdfe  ROE  stlnequity  Fascista19441950 Fascista1951Plus  total_tons total_tons19431950 total_tons1951Plus  if FROE1939!=.& FROE1950!=., absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m106

/*These are to generate Table 8*/
reghdfe  ROE  stlnequity stLeverage FascistaPost1917 Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)

est sto m1

reghdfe  ROE  stlnequity stLeverage FascistaPost1917 Fascista19441950 Fascista1951Plus ConnectedPreWW11917Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)

est sto m2

reghdfe  ROE  stlnequity stLeverage  Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus MarshallPlanGrantPost1948, absorb(id  i.Anno i.Ss_n i.Prov_n) cluster(id)

est sto m3

sort Ss_n
by Ss_n: egen VeryFascista=mean(Fascista)
summarize  VeryFascista, detail
reghdfe  ROE  stlnequity stLeverage  Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus if (VeryFascista>= .3178129), absorb(id  i.Anno i.Ss_n i.Prov_n) cluster(id)

est sto m4
reghdfe  ROE  stlnequity stLeverage  Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus if (VeryFascista< .3178129& VeryFascista!=.), absorb(id  i.Anno i.Ss_n i.Prov_n) cluster(id)

est sto m5

sort Anno -CapSoc
by Anno: gen groupid=_n/10
gen integergroupid=int(groupid)
tabulate  integergroupid
sort Anno - UtilePerdita
by Anno: gen groupid2=_n/10
gen integergroupid2=int(groupid2)
reghdfe  ROE  stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n integergroupid integergroupid2) cluster(id)
est sto m6

gen Yr1933Plus=1
replace Yr1933Plus=0 if Anno<1933
reghdfe  ROE  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id##Yr1933Plus i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m7

gen Connected1921=NumberConn* SenatorFY if Anno==1921
replace Connected1921=1 if Connected1921>0& Connected1921<100
tabulate Connected1921
bysort id: fillmissing Connected1921, with(max)
replace Connected1921=0 if Connected1921==.
summarize Connected1921
gen Connected1921Fascist= Connected1921*Fascista
gen Connected1921Fascist19441950=Connected1921Fascist
replace Connected1921Fascist19441950=0 if Anno<1944|Anno>1950
gen Connected1921Fascist1951Plus=Connected1921Fascist
replace Connected1921Fascist1951Plus=0 if Anno<1951
gen FascistaEndogenous=Fascista if Connected1921Fascist==0

reghdfe  ROE  stlnequity stLeverage Fascista19441950 Fascista1951Plus  total_tons total_tons19431950 total_tons1951Plus if FascistaEndogenous!=1&( Connected1921==0&Fascista==0| Connected1921==1& EligibleF!=0), absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)

est sto m8

replace Fascista19441950Kept =1 if Fascista19441950Kept >0&Fascista19441950Kept <1

reghdfe  ROE  stlnequity stLeverage Fascista19441950 Fascista19441950Kept Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m9

reghdfe  ROE2  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m10


reghdfe  ROE3  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m11


esttab m1 m2 m3 m4 m5 m6 m7 m8 m9 m10 m11, se star( * 0.1 ** 0.05 *** 0.01) scalar(F) r2
esttab m1 m2 m3 m4 m5 m6 m7 m8 m9 m10 m11 using "C:\Papers\New papers\John Cronyism\Italy\Table8.csv", replace starl( * 0.10 ** 0.05 *** 0.010) stats(N r2 ar2)  se(3) b(3) nogap
eststo clear


tsset id Anno

/* MB is MB from Mediobanca or, if unavailable, from Il Sole */

/*Skip there is insufficient data in pseudo files
reghdfe  lnMB  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus   , absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m1
reghdfe  lnMB  stlnequity stLeverage Fascista19441950 Fascista1951Plus total_tons total_tons19431950 total_tons1951Plus   if Anno>1938, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)
est sto m2

esttab m1 m2, se star( * 0.1 ** 0.05 *** 0.01) scalar(F) r2
esttab m1 m2 using "C:\Papers\New papers\John Cronyism\Italy\Table10.csv", replace starl( * 0.10 ** 0.05 *** 0.010) stats(N r2 ar2)  se(3) b(3) nogap
eststo clear*/


/*Summary stats*/
summarize ROE DuPontsROA MB lnMB  Fascista CapSoc Attivo Leverage total_tonsold Anno After if Fascista!=.



sort id Anno
tsset id Anno
gen Kept=1 if F.id!=.
replace Kept=0 if F.id ==.&Kept!=1
reghdfe Kept  stlnequity Fascista1940 Fascista1941 Fascista1942 Fascista1943 Fascista1944 Fascista1945 Fascista1946 Fascista1947 Fascista1948 Fascista1949 Fascista1950 Fascista1951 Fascista1952 Fascista1953 Fascista1954 Fascista1955 Fascista1956 Fascista1957 Fascista1958 Fascista1959 Fascista1960 total_tons total_tons1943 total_tons1944 total_tons1945 total_tons1946 total_tons1947 total_tons1948 total_tons1949 total_tons1950 total_tons1951 total_tons1952 total_tons1953 total_tons1954 total_tons1955 total_tons1956 total_tons1957 total_tons1958 total_tons1959 total_tons1960, absorb(id i.Anno i.Ss_n i.Prov_n) cluster(id)


/* Figure 1*/
clear
use "C:\Papers\New papers\John Cronyism\Italy\Bilanci10.dta", clear
gen ROEnonmissing=1 if ROE!=.
sort id
by id: egen InSampleDuringFascism=max(ROEnonmissing) if ROE!=.&Anno>=1921&Anno<=1943
by id: egen InSampleDuringFascismF=max(InSampleDuringFascism)
by id: egen InSampleAfterFascism=max(ROEnonmissing) if ROE!=.&Anno>=1944&Anno<=1960
by id: egen InSampleAfterFascismF=max(InSampleAfterFascism)
drop InSampleDuringFascism  InSampleAfterFascism
sort Fascista
by Fascista: summarize ROE if InSampleDuringFascismF==1&InSampleAfterFascismF==1&Anno>=1911&Anno<=1920
by Fascista: summarize ROE if InSampleDuringFascismF==1&InSampleAfterFascismF==1&Anno>=1921&Anno<=1943
by Fascista: summarize ROE if InSampleDuringFascismF==1&InSampleAfterFascismF==1&Anno>=1944&Anno<=1950
by Fascista: summarize ROE if InSampleDuringFascismF==1&InSampleAfterFascismF==1& Anno>=1951&Anno<=1960

sort Fascista Anno
collapse (mean) ROE if InSampleDuringFascismF==1&InSampleAfterFascismF==1, by(Fascista Anno)
drop if Fascista==.
reshape wide ROE , i( Anno ) j(Fascista)
gen ROE_Difference= ROE1-ROE0
scatter ROE_Difference Anno, ytitle("Difference in Average ROE") xtitle("Year")
graph save "Graph" "C:\Papers\New papers\John Cronyism\Italy\ROEDifference.gph", replace
graph save "Graph" "C:\Papers\New papers\John Cronyism\Italy\Relative ROE.gph", replace
clear
clear all
frame change default
graph use "C:\Papers\New papers\John Cronyism\Italy\ROEDifference.gph"
clear

/*For specification curve*/
graph set window fontface "Times New Roman"
clear
net install specurve, from("https://raw.githubusercontent.com/mgao6767/specurve/master") replace
use "http://www.stata-press.com/data/r13/nlswork.dta", clear
copy "https://mingze-gao.com/specurve/example_config_nlswork_reghdfe.yml" ., replace
ssc install ivreghdfe
clear all

clear
use "C:\Papers\New papers\John Cronyism\Italy\Bilanci10.dta", clear
cd "C:\Papers\New papers\John Cronyism\Italy\"
use Bilanci10.dta, clear
frame change default
/*The line below is for the yml file that Renyuan prepared*/
/*specurve using Sept20Demo1.yml, saving(Demo1, replace)*/
/*The command below is for spec curve for ROE defined as income/end of year equity*/
specurve using PolConnResMisROE.yml, nodependent nofocal nocluster width(50) height(100) relativesize(0.1) saving(Demo0, replace)
graph save "Graph" "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisROE.gph", replace
frame change default
clear
graph use "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisROE.gph"
clear

clear
use "C:\Papers\New papers\John Cronyism\Italy\Bilanci10.dta", clear
cd "C:\Papers\New papers\John Cronyism\Italy\"
use Bilanci10.dta, clear
frame change default
/*The command below is for spec curve for ROE2 defined as income/end of year equity*/
specurve using PolConnResMisROE2.yml, nodependent nofocal nocluster width(50) height(100) relativesize(0.1) saving(Demo3, replace)
graph save "Graph" "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisROE2.gph", replace
frame change default
clear
graph use "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisROE2.gph"
clear

clear
use "C:\Papers\New papers\John Cronyism\Italy\Bilanci10.dta", clear
cd "C:\Papers\New papers\John Cronyism\Italy\"
use Bilanci10.dta, clear
frame change default
/*The command below is for spec curve for ROE3*/
specurve using PolConnResMisROE3.yml, nodependent nofocal nocluster width(50) height(100) relativesize(0.1) saving(Demo4, replace)
graph save "Graph" "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisROE3.gph", replace
frame change default
clear
graph use "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisROE3.gph"
clear

clear
use "C:\Papers\New papers\John Cronyism\Italy\Bilanci10.dta", clear
cd "C:\Papers\New papers\John Cronyism\Italy\"
use Bilanci10.dta, clear
frame change default
/*The command below is for spec curve for DuPont's ROA*/
specurve using PolConnResMisROA.yml, nodependent nofocal nocluster width(50) height(100) relativesize(0.1) saving(DuPontsROA, replace)
graph save "Graph" "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisDuPontsROA.gph", replace
clear
graph use "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisDuPontsROA.gph"
clear

/*Skip insufficient data in pseudo file for MB
clear
use "C:\Papers\New papers\John Cronyism\Italy\Bilanci10.dta", clear
cd "C:\Papers\New papers\John Cronyism\Italy\"
use Bilanci10.dta, clear
frame change default
winsor2 lnMB, cuts(1 99) replace by(Anno)
/*The command below is for spec curve for lnMB*/
specurve using PolConnResMisMB.yml, nodependent nofocal nocluster width(50) height(100) relativesize(0.1) saving(Demo5, replace)
graph save "Graph" "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisMB.gph", replace
frame change default
clear
graph use "C:\Papers\New papers\John Cronyism\Italy\PolConnResMisMB.gph"*/
clear
clear all
